//
// Description: OpenGL 引擎实现类
// Created by zhangdong on 2021/7/24.
//

#include "engine_impl.h"

// 单例模式
IEngine *EngineImpl::getInstance() {
    if (nullptr == m_instance) {
        m_instance = new EngineImpl();
    }
    return m_instance;
}

EngineImpl::EngineImpl() {

}

EngineImpl::~EngineImpl() {
    closeCamera();
    if (m_cam) {
        delete m_cam;
        m_cam = nullptr;
    }
}

void EngineImpl::init() {
    m_cam = new CameraImpl();
}

void EngineImpl::unInit() {

}

void EngineImpl::openCamera() {

}

void EngineImpl::closeCamera() {

}
